<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="utf-8">
<!-- creator-valgrind-overview.qdoc -->
  <title>Using Valgrind Code Analysis Tools | Qt Creator Manual</title>
  <link rel="stylesheet" type="text/css" href="style/offline-simple.css" />
  <script type="text/javascript">
    document.getElementsByTagName("link").item(0).setAttribute("href", "style/offline.css");
    // loading style sheet breaks anchors that were jumped to before
    // so force jumping to anchor again
    setTimeout(function() {
        var anchor = location.hash;
        // need to jump to different anchor first (e.g. none)
        location.hash = "#";
        setTimeout(function() {
            location.hash = anchor;
        }, 0);
    }, 0);
  </script>
</head>
<body>
<div class="header" id="qtdocheader">
  <div class="main">
    <div class="main-rounded">
      <div class="navigationbar">
        <table><tr>
<td ><a href="index.html">Qt Creator Manual</a></td><td >Using Valgrind Code Analysis Tools</td></tr></table><table class="buildversion"><tr>
<td id="buildversion" width="100%" align="right"><a href="index.html">Qt Creator Manual 4.11.1</a></td>
        </tr></table>
      </div>
    </div>
<div class="content">
<div class="line">
<div class="content mainContent">
  <link rel="prev" href="creator-qml-performance-monitor.html" />
  <link rel="next" href="creator-analyzer.html" />
<p class="naviNextPrevious headerNavi">
<a class="prevPage" href="creator-qml-performance-monitor.html">Profiling QML Applications</a>
<span class="naviSeparator">  &#9702;  </span>
<a class="nextPage" href="creator-analyzer.html">Detecting Memory Leaks with Memcheck</a>
</p><p/>
<div class="sidebar"><div class="sidebar-content" id="sidebar-content"></div></div>
<h1 class="title">Using Valgrind Code Analysis Tools</h1>
<span class="subtitle"></span>
<!-- $$$creator-valgrind-overview.html-description -->
<div class="descr"> <a name="details"></a>
<p>Qt Creator integrates <a href="http://valgrind.org/info/tools.html">Valgrind code analysis tools</a> for detecting memory leaks and profiling function execution. You must download and install them separately to use them from Qt Creator.</p>
<p>You can run the Valgrind tools either <i>locally</i> on the development host or <i>remotely</i> on another host. You can use them to analyze both applications for which you set up a project in Qt Creator and applications for which you do not have a project.</p>
<p>Valgrind tools are supported locally only on Linux and <a href="nolink">macOS</a>. However, according to Valgrind.org, support on <a href="nolink">macOS</a> 10.8 and 10.9 is experimental and mostly broken. You can run the tools on a remote Linux machine or device from any development host.</p>
<p>To run the Valgrind tools to analyze an application for which you have a project, open the project in Qt Creator and select the kit to run the project. The kit specifies whether the Valgrind tools are run locally or remotely.</p>
<p>For more information about analyzing applications for which you do not have a project, see <a href="creator-running-valgrind-remotely.html">Running Valgrind Tools on External Applications</a>.</p>
<p>To select options for the Valgrind tools, select <b>Tools &gt; Options &gt; Analyzer</b>. You can override the general settings for each project in the <b>Run Settings</b> for the project.</p>
<p>The following sections describe how to use the Valgrind tools:</p>
<ul>
<li><a href="creator-analyzer.html">Detecting Memory Leaks with Memcheck</a></li>
<li><a href="creator-cache-profiler.html">Profiling Function Execution</a></li>
</ul>
</div>
<!-- @@@creator-valgrind-overview.html -->
<p class="naviNextPrevious footerNavi">
<a class="prevPage" href="creator-qml-performance-monitor.html">Profiling QML Applications</a>
<span class="naviSeparator">  &#9702;  </span>
<a class="nextPage" href="creator-analyzer.html">Detecting Memory Leaks with Memcheck</a>
</p>
        </div>
       </div>
   </div>
   </div>
</div>
<div class="footer">
   <p>
   <acronym title="Copyright">&copy;</acronym> 2019 The Qt Company Ltd.
   Documentation contributions included herein are the copyrights of
   their respective owners.<br>    The documentation provided herein is licensed under the terms of the    <a href="http://www.gnu.org/licenses/fdl.html">GNU Free Documentation    License version 1.3</a> as published by the Free Software Foundation.<br>    Qt and respective logos are trademarks of The Qt Company Ltd.     in Finland and/or other countries worldwide. All other trademarks are property
   of their respective owners. </p>
</div>
</body>
</html>
